


// 器材调拨
import request from "@/api/request";

// 分页查询器材调拨单
export const query_equipmentTransferSlip = (params) => {
  return request({
    url: "/equipmentmanage/ea/selectAll",
    method: "post",
    data: params,
  });
};

// 新增器材调拨单
export const add_equipmentTransferSlip = (params) => {
  return request({
    url: "/equipmentmanage/ea/insert",
    method: "post",
    data: params,
    headers: { "Content-Type": "application/json;charset=UTF-8" },
  });
};

// 逻辑删除器材调拨单
export const delete_equipmentTransferSlip = (params) => {
  return request({
    url: `/equipmentmanage/ea/delete/${params}`,
    method: "post",
    data: params,
  });
};

// 修改器材调拨单
export const update_equipmentTransferSlip = (params) => {
  return request({
    url: "/equipmentmanage/ea/update",
    method: "post",
    data: params,
    headers: { "Content-Type": "application/json;charset=UTF-8" },
  });
};

// 查询器材调拨单详情
export const select_equipmentTransferSlip = (params) => {
  return request({
    url: `/equipmentmanage/ea/selectdetails/${params}`,
    method: "post",
    data: params,
  });
};

//  查询部门列表
export const query_exportdepartment = () => {
  return request({
    url: "/equipmentmanage/ea/orglist",
    method: "post",
    headers: { "Content-Type": "application/json;charset=UTF-8" },
  });
};
//  查询人员列表
export const query_personnellist = (params) => {
  return request({
    url: "/equipmentmanage/ea/userList/"+params,
    method: "post",
    headers: { "Content-Type": "application/json;charset=UTF-8" },
  });
};

//  查询仓库列表
export const query_warehouselist = () => {
  return request({
    url: "/equipmentmanage/ea/depotlist",
    method: "post",
    headers: { "Content-Type": "application/json;charset=UTF-8" },
  });
};

//  查询储位列表
export const query_Addresslist = () => {
  return request({
    url: "/equipmentmanage/ea/proorglist",
    method: "post",
    headers: { "Content-Type": "application/json;charset=UTF-8" },
  });
};

// 提交
export const query_commit = (params) => {
  return request({
    url: "/equipmentmanage/ea/commit",
    method: "post",
    data:params,
    headers: { "Content-Type": "application/json;charset=UTF-8" },
  });
};

// 审核
export const query_audit = (params) => {
  return request({
    url: "/equipmentmanage/ea/audit",
    method: "post",
    data:params,
    headers: { "Content-Type": "application/json;charset=UTF-8" },
  });
};

// 回退
export const query_undo = (params) => {
  return request({
    url: "/equipmentmanage/ea/undo",
    method: "post",
    data:params,
  });
};

// 审核历史
export const query_history = (params) => {
  return request({
    url: "/equipmentmanage/ea/getAuditHistory",
    method: "post",
    data:params,
  });
};

// 作废
export const query_cancel = (params) => {
  return request({
    url: "/equipmentmanage/ea/cancel",
    method: "post",
    data:params,
  });
};

// 逻辑删除器材调拨单
export const delete_deleteByFId = (params) => {
  return request({
    url: `/equipmentmanage/ea/deleteByFId/${params}`,
    method: "post",
    data: params,
  });
};